from selenium import webdriver
from time import sleep
from selenium.webdriver import ActionChains
from selenium.webdriver.common.by import By
from selenium import webdriver
# 导入 Service 类（关键）
from selenium.webdriver.chrome.service import Service

#实例化对象：

service = Service(executable_path="E:\\python\\python38\\chromedriver.exe")
driver = webdriver.Chrome(service=service)
driver.get("http://121.43.169.97:8848/pageA.html")
action = ActionChains(driver)
#通过css定位，标签option value定位
driver.find_element(By.CSS_SELECTOR,"[value='sh']").click()
sleep(2)
driver.find_element(By.CSS_SELECTOR,"[value='gz']").click()
sleep(2)
